    
    TestCase
    (
        'ie.ondevice.objectkit.FunctionIsTestCase'

    ,   {
            
            testPrimitiveAndIsGeneralCase: function () 
            {
                
                var stringPrimitive= 'string'
                ,   stringObject= new String(stringPrimitive)
                
                assertTrue('stringPrimitive is a primitive string', 'string' === typeof stringPrimitive);
                assertFalse('stringPrimitive is not a string object', stringPrimitive instanceof String);
                assertFalse('stringObject is not a primitive string', 'string' === typeof stringObject); 
                assertTrue('stringObject is a string object', stringObject instanceof String);    
                assertEquals('primitives and objects are considered eqal', stringPrimitive, stringObject);
                assertNotSame('primitives and objects are not considered identical', stringPrimitive, stringObject);
                assertInstanceOf('stringPrimitives are autoboxed', Function, stringPrimitive.charAt);
                
                assertTrue('String.is returns true for stringPrimitive', String.is(stringPrimitive));
                assertTrue('String.is returns true for stringObject', String.is(stringObject));
            }
            
        ,   testPrimitiveNumberIs: function () 
            {
                
                var numberPrimitive= 0
                ,   numberObject= new Number(numberPrimitive)
                ,   numberLike= '2'
                
                // JavaScript WTF wierdness-
                
                // NaN ('Not A Number') is considered a primitive number by the
                // typeof operator
                assertTrue('NaN is a type of number', 'number' === typeof NaN);
                
                // isNaN fails for null, meaning isNaN considers null a number!
                assertFalse('isNaN returns true for null', isNaN(null));
                
                // isNaN however considers undefined as not a number
                assertTrue('isNaN returns true for undefined', isNaN(void(0)));
                
                // NaN is not identical with itself!
                assertFalse('NaN is not identical to NaN', NaN === NaN);
                // Nan is not equal to itself!
                assertFalse('NaN is not equal to itself', NaN == NaN);
                assertFalse('NaN is not an instance of Number', NaN instanceof Number);
                assertTrue('Infinity is a type of number', 'number' === typeof Infinity);
                assertFalse('Infinity is not NaN', isNaN(Infinity));
                assertTrue('NaN is not a number', isNaN(NaN));
                
                assertFalse('Number.is returns false for numberLike', Number.is(numberLike));
                assertFalse('Number.is returns false for null', Number.is(null));
                assertFalse('Number.is returns false for undefined', Number.is(void(0)));
                assertTrue('Number.is returns true for numberPrimitive', Number.is(numberPrimitive));
                assertTrue('Number.is returns true for numberObject', Number.is(numberObject));
                assertTrue('Number.is returns true for Infinity', Number.is(Infinity));
                assertFalse('Number.is returns false for NaN', Number.is(NaN));
            }
            
        ,   testFunctionIsWithCustomTypes: function () 
            {
                
                function CustomType () {;};
                
                assertTrue('The extension works with custom objects', CustomType.is(new CustomType));
                assertTrue('The extension works with custom objects and natives', Object.is(new CustomType));
            }
            


        ,   testIsWithNullAndUndefined: function () 
            {
                assertFalse('Object.is returns false for null', Object.is(null));
                assertFalse('Object.is returns false for undefined', Object.is(void(0)));
            }
        }
    );